An Imperative Core Calculus for Java
نویسنده
چکیده
This technical report presents the specification of a programming language Cool: the Core Object-Oriented Language. Cool is a small language but retains many of the features of modern class-based object-oriented languages, including primitive types, classes, inheritance, objects, instance variables and methods, dynamic method binding, null and arrays, etc.. The specification for Cool in this report is formal. First, this paper give syntactic specifications for Cool; second, we define static semantics for Cool via typing rules; and finally, we define its operational semantics. In stark contrast to any previous research effort in this area, we introduce side conditions into Cool’s type system, which express important safety obligations.
منابع مشابه
MJ: An imperative core calculus for Java and Java with effects
In order to study rigorously object-oriented languages such as Java or C, a com-mon practice is to define lightweight fragments, or calculi, which are sufficiently smallto facilitate formal proofs of key properties. However many of the current proposals forcalculi lack important language features. In this paper we propose Middleweight Java,MJ, as a contender for a minimal im...
متن کاملEffects and effect inference for a core Java calculus
An effects system can be used to delimit the scope of computational effects within a program. This information is not only useful for the programmer, but also can be used in the definition of a number of optimizations. Most effects systems have been defined for functional languages with simple state. Greenhouse and Boyland have recently suggested how an effects system could be used within Java....
متن کاملAn Imperative , First - Order Calculus withObject
This paper presents an imperative object calculus designed to support class-based programming via a combination of extensible objects and encapsulation. This calculus simpliies the language presented in 17] in that, like C++ and Java, it chooses to support an imperative semantics instead of method specialization. We show how Java-style classes and \mixins" may be coded in this calculus, prove a...
متن کاملAn Imperative, First-Order Calculus with Object Extension
This paper presents an imperative object calculus designed to support class-based programming via a combination of extensible objects and encapsulation. This calculus simplifies the language presented in [17] in that, like C++ and Java, it chooses to support an imperative semantics instead of method specialization. We show how Java-style classes and “mixins” may be coded in this calculus, prove...
متن کاملWelterweight Java
This paper presents Welterweight Java (WJ), a new minimal core Java calculus intended to be a suitable starting point for investigations in the semantics of Java-like programs. To this end, WJ adds a few extra pounds to Featherweight Java. WJ is imperative and stateful, which is a frequent extension of Featherweight Java. To account for the importance of concurrency, WJ models Java’s thread-bas...
متن کامل